// Easy GUI Library
//
// Copyright (C) 2008 John Torjo (see http://torjo.com/contact/ for email)
//
// Permission to copy, use, sell and distribute this software is granted
// provided this copyright notice appears in all copies.
// Permission to modify the code and to distribute modified code is granted
// provided this copyright notice appears in all copies, and a notice
// that the code was modified is included with the copyright notice.
//
// This software is provided "as is" without express or implied warranty,
// and with no claim as to its suitability for any purpose.
//
// You can find the latest version of this library at http://www.torjo.com/egui/

#ifndef JOHN_TORJO_WIN32GUI_detail_raw_struct_wrappers
#define JOHN_TORJO_WIN32GUI_detail_raw_struct_wrappers

#if defined(_MSC_VER) && (_MSC_VER >= 1020)
# pragma once
#endif

// Allows converting from our types (like, rectangle, point, etc) to raw win32 types

#include "egui/core/wnd.hpp"

namespace egui { namespace win32 {

SIZE to(const size & sz);
POINT to(const point & p);
RECT to(const rectangle & rect);

size from(const SIZE & sz);
point from(const POINT & p);
rectangle from(const RECT & rect);

COLORREF to(const types::color & c);
types::color from(const COLORREF & c);

SYSTEMTIME to(const time_t & t);
time_t from(const SYSTEMTIME & s);



HIMAGELIST to(const image_list_base & i);
temporary_image_list from(const HIMAGELIST & h);

HBITMAP to(const bitmap_base & b);
temporary_bitmap from(const HBITMAP & h);

HICON to(const icon_base & i);
temporary_icon from(const HICON & h);

HFONT to(const font_base & f);
temporary_font from(const HFONT & h);


UINT get_wm_msg(const ev::base & event);
WPARAM get_wparam(const ev::base & event);
LPARAM get_lparam(const ev::base & event);

}}


#endif // JOHN_TORJO_WIN32GUI_detail_raw_struct_wrappers
